import React from 'react'
import { Icon } from 'gantd'
export const columns = [
	{
		title: tr('类型'),
		fieldName: 'type'
	},
	{
		title: tr('名称'),
		fieldName: 'name'
	},
	{
		title: tr('系统'),
		fieldName: 'category',
    width: 100,
    filter: false,
		render: (text: string) => text == "SYSTEM" ? <span className="successColor" ><Icon.Ant type="check-circle" /></span> : ""
	}

]

export const searchFormschema = {
	type: {
		title: tr('类型'),
	},
	name: {
		title: tr('名称'),
	},
	category: {
		title: tr('类别'),
		componentType: "Selector",
		props: {
			useStorage: false,
			dataSource: [{
				label: tr("全部编码"),
				value: "ALL"
			}, {
				label: tr("系统编码"),
				value: "SYSTEM"
			},
			{
				label: tr("自定义编码"),
				value: "CUSTOM"
			}
			]
		}
	}
}

export const searchUISchema = {
	"ui:col": 8
}
